user@300S:~$ cd /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0
user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ export 
user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ export ACUITY_PATH=`pwd`/bin
user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ ./pegasus_import.sh lenet/
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0
=========== Converting lenet Caffe model ===========
python3 /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/bin/pegasus.py import caffe --model lenet.prototxt --weights lenet.caffemodel --output-model lenet.json --output-data lenet.data
2021-09-28 18:26:22.696700: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory
2021-09-28 18:26:22.696735: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
I Namespace(import='caffe', model='lenet.prototxt', output_data='lenet.data', output_model='lenet.json', proto='caffe', weights='lenet.caffemodel', which='import')
I Start importing caffe...
I Set caffe proto to caffe
I Load caffe model lenet.prototxt
I Parsing net parameters ... 
I Parsing layer parameters ... 
D Convert layer input
D Convert layer conv1
D Convert layer pool1
D Convert layer conv2
D Convert layer pool2
D Convert layer ip1
D Convert layer relu1
D Convert layer ip2
D Convert layer prob
I Parsing connections ... 
D Connect: input_0,0 to conv1_1,0
D Connect: conv1_1,0 to pool1_2,0
D Connect: pool1_2,0 to conv2_3,0
D Connect: conv2_3,0 to pool2_4,0
D Connect: pool2_4,0 to ip1_5,0
D Connect: ip1_5,0 to relu1_6,0
D Connect: relu1_6,0 to ip2_7,0
D Connect: ip2_7,0 to prob_8,0
D Connect: prob_8,0 to output_9,0,
I Load net complete.
2021-09-28 18:26:24.872692: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2021-09-28 18:26:24.890344: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2599990000 Hz
2021-09-28 18:26:24.890574: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x656aeb0 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2021-09-28 18:26:24.890635: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2021-09-28 18:26:24.894248: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory
2021-09-28 18:26:24.894563: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)
2021-09-28 18:26:24.894608: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (300S): /proc/driver/nvidia/version does not exist
D Process input_0 ...
D Acuity output shape(input): (0 1 28 28)
D Tensor @input_0:out0 type: float32
D Process conv1_1 ...
D Acuity output shape(convolution): (0 20 24 24)
D Tensor @conv1_1:out0 type: float32
D Process pool1_2 ...
D Acuity output shape(pooling): (0 20 12 12)
D Tensor @pool1_2:out0 type: float32
D Process conv2_3 ...
D Acuity output shape(convolution): (0 50 8 8)
D Tensor @conv2_3:out0 type: float32
D Process pool2_4 ...
D Acuity output shape(pooling): (0 50 4 4)
D Tensor @pool2_4:out0 type: float32
D Process ip1_5 ...
D Acuity output shape(fullconnect): (0 500)
D Tensor @ip1_5:out0 type: float32
D Process relu1_6 ...
D Acuity output shape(relu): (0 500)
D Tensor @relu1_6:out0 type: float32
D Process ip2_7 ...
D Acuity output shape(fullconnect): (0 10)
D Tensor @ip2_7:out0 type: float32
D Process prob_8 ...
D Acuity output shape(softmax): (0 10)
D Tensor @prob_8:out0 type: float32
D Process output_9 ...
D Acuity output shape(output): (0 10)
D Tensor @output_9:out0 type: float32
I Build LeNet complete.
I Load blobs from caffe model lenet.caffemodel
I Check if lenet.caffemodel contains 'type' value
W prob in prototxt does not exist in caffemodel.
W Above layers in prototxt mismatch with caffemodel.
I Parsing net blobs ... 
D Load blobs of conv1
I pool1 in caffemodel have blobs, we could skip this blobs.
D Load blobs of conv2
I pool2 in caffemodel have blobs, we could skip this blobs.
D Load blobs of ip1
I relu1 in caffemodel have blobs, we could skip this blobs.
D Load blobs of ip2
W loss in caffemodel have blobs, but this op softmaxwithloss do not have proper blobs process function,
This may cause prototxt-caffemodel-mismatch layers' data missing.
I Load blobs complete.
D Optimizing network with insert_reshape, strip_noop_multi_out, broadcast_const_data
I Start C2T Switcher...
D Optimizing network with broadcast_op
D insert permute conv1_1_acuity_mark_perm_10 before conv1_1
I End C2T Switcher...
D Process input_0 ...
D Acuity output shape(input): (0 1 28 28)
D Tensor @input_0:out0 type: float32
D Process conv1_1_acuity_mark_perm_10 ...
D Acuity output shape(permute): (0 28 28 1)
D Tensor @conv1_1_acuity_mark_perm_10:out0 type: float32
D Process conv1_1 ...
D Acuity output shape(convolution): (0 24 24 20)
D Tensor @conv1_1:out0 type: float32
D Process pool1_2 ...
D Acuity output shape(pooling): (0 12 12 20)
D Tensor @pool1_2:out0 type: float32
D Process conv2_3 ...
D Acuity output shape(convolution): (0 8 8 50)
D Tensor @conv2_3:out0 type: float32
D Process pool2_4 ...
D Acuity output shape(pooling): (0 4 4 50)
D Tensor @pool2_4:out0 type: float32
D Process ip1_5 ...
D Acuity output shape(fullconnect): (0 500)
D Tensor @ip1_5:out0 type: float32
D Process relu1_6 ...
D Acuity output shape(relu): (0 500)
D Tensor @relu1_6:out0 type: float32
D Process ip2_7 ...
D Acuity output shape(fullconnect): (0 10)
D Tensor @ip2_7:out0 type: float32
D Process prob_8 ...
D Acuity output shape(softmax): (0 10)
D Tensor @prob_8:out0 type: float32
D Process output_9 ...
D Acuity output shape(output): (0 10)
D Tensor @output_9:out0 type: float32
I Build LeNet complete.
D Optimizing network with force_1d_tensor, special_clip_to_relun, swapper, merge_duplicate_quantize_dequantize, merge_layer, auto_fill_bn, auto_fill_l2normalizescale, auto_fill_instancenormalize, resize_nearest_transformer, auto_fill_multiply, compute_gather_negative, auto_fill_zero_bias, proposal_opt_import, special_add_to_conv2d, extend_gather_to_gather_reshape
I End importing caffe...
I Dump net to lenet.json
I Save net to lenet.data
W ----------------Error(0),Warning(3)----------------
import SUCCESS 
=========== Generate lenet inputmeta file ===========
python3 /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/bin/pegasus.py generate inputmeta --model lenet.json --separated-database --input-meta-output lenet_inputmeta.yml
2021-09-28 18:26:25.884331: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory
2021-09-28 18:26:25.884363: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
I Namespace(generate='inputmeta', input_meta_output='lenet_inputmeta.yml', model='lenet.json', separated_database=True, which='generate')
I Load model in lenet.json
I Generate input meta lenet_inputmeta.yml
I ----------------Error(0),Warning(0)----------------
generate NAME inputmeta ! 
pls modify the contents of lenet_inputmeta.yml ! 
=========== Generate lenet postprocess_file file ===========
python3 /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/bin/pegasus.py generate postprocess-file --model lenet.json --postprocess-file-output lenet_postprocess_file.yml
2021-09-28 18:26:28.828192: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory
2021-09-28 18:26:28.828227: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
I Namespace(generate='postprocess-file', model='lenet.json', postprocess_file_output='lenet_postprocess_file.yml', which='generate')
I Load model in lenet.json
2021-09-28 18:26:30.911268: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2021-09-28 18:26:30.917193: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2599990000 Hz
2021-09-28 18:26:30.917496: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x64ac070 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2021-09-28 18:26:30.917517: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2021-09-28 18:26:30.919257: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory
2021-09-28 18:26:30.919289: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)
2021-09-28 18:26:30.919310: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (300S): /proc/driver/nvidia/version does not exist
D Process input_0 ...
D Acuity output shape(input): (0 1 28 28)
D Tensor @input_0:out0 type: float32
D Process conv1_1_acuity_mark_perm_10 ...
D Acuity output shape(permute): (0 28 28 1)
D Tensor @conv1_1_acuity_mark_perm_10:out0 type: float32
D Process conv1_1 ...
D Acuity output shape(convolution): (0 24 24 20)
D Tensor @conv1_1:out0 type: float32
D Process pool1_2 ...
D Acuity output shape(pooling): (0 12 12 20)
D Tensor @pool1_2:out0 type: float32
D Process conv2_3 ...
D Acuity output shape(convolution): (0 8 8 50)
D Tensor @conv2_3:out0 type: float32
D Process pool2_4 ...
D Acuity output shape(pooling): (0 4 4 50)
D Tensor @pool2_4:out0 type: float32
D Process ip1_5 ...
D Acuity output shape(fullconnect): (0 500)
D Tensor @ip1_5:out0 type: float32
D Process relu1_6 ...
D Acuity output shape(relu): (0 500)
D Tensor @relu1_6:out0 type: float32
D Process ip2_7 ...
D Acuity output shape(fullconnect): (0 10)
D Tensor @ip2_7:out0 type: float32
D Process prob_8 ...
D Acuity output shape(softmax): (0 10)
D Tensor @prob_8:out0 type: float32
D Process output_9 ...
D Acuity output shape(output): (0 10)
D Tensor @output_9:out0 type: float32
I Build LeNet complete.
I Generate postprocess file lenet_postprocess_file.yml
I ----------------Error(0),Warning(0)----------------
generate NAME postprocess_file ! 
pls modify the contents of lenet_postprocess_file.yml ! 
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0

user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ ./pegasus_quantize.sh lenet/ uint8
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0
=======================================================================
==== Start Quantizing lenet model with type of  ===
=======================================================================
python3 /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/bin/pegasus.py quantize --model lenet.json --model-data lenet.data --device CPU --with-input-meta lenet_inputmeta.yml --compute-entropy --rebuild --model-quantize lenet_uint8.quantize --quantizer asymmetric_affine --qtype uint8
2021-09-28 18:27:46.481601: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory
2021-09-28 18:27:46.481635: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
I Namespace(algorithm='normal', batch_size=0, compute_entropy=True, device='CPU', divergence_first_quantize_bits=11, divergence_nbins=0, hybrid=False, iterations=1, model='lenet.json', model_data='lenet.data', model_quantize='lenet_uint8.quantize', moving_average_weight=0.01, output_dir=None, qtype='uint8', quantizer='asymmetric_affine', rebuild=True, rebuild_all=False, which='quantize', with_input_meta='lenet_inputmeta.yml')
I Load model in lenet.json
I Load data in lenet.data
I Load input meta lenet_inputmeta.yml
I Start quantization...
2021-09-28 18:27:48.653050: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2021-09-28 18:27:48.658978: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2599990000 Hz
2021-09-28 18:27:48.659253: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x72a6610 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2021-09-28 18:27:48.659274: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2021-09-28 18:27:48.661199: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory
2021-09-28 18:27:48.661218: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)
2021-09-28 18:27:48.661240: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (300S): /proc/driver/nvidia/version does not exist
D set up a quantize net
D Process input_0 ...
D Acuity output shape(input): (1 1 28 28)
D Tensor @input_0:out0 type: float32
D Process conv1_1_acuity_mark_perm_10 ...
D Acuity output shape(permute): (1 28 28 1)
D Tensor @conv1_1_acuity_mark_perm_10:out0 type: asymmetric_affine
D Process conv1_1 ...
D Acuity output shape(convolution): (1 24 24 20)
D Tensor @conv1_1:out0 type: asymmetric_affine
D Process pool1_2 ...
D Acuity output shape(pooling): (1 12 12 20)
D Tensor @pool1_2:out0 type: asymmetric_affine
D Process conv2_3 ...
D Acuity output shape(convolution): (1 8 8 50)
D Tensor @conv2_3:out0 type: asymmetric_affine
D Process pool2_4 ...
D Acuity output shape(pooling): (1 4 4 50)
D Tensor @pool2_4:out0 type: asymmetric_affine
D Process ip1_5 ...
D Acuity output shape(fullconnect): (1 500)
D Tensor @ip1_5:out0 type: asymmetric_affine
D Process relu1_6 ...
D Acuity output shape(relu): (1 500)
D Tensor @relu1_6:out0 type: asymmetric_affine
D Process ip2_7 ...
D Acuity output shape(fullconnect): (1 10)
D Tensor @ip2_7:out0 type: asymmetric_affine
D Process prob_8 ...
D Acuity output shape(softmax): (1 10)
D Tensor @prob_8:out0 type: float32
D Process output_9 ...
D Acuity output shape(output): (1 10)
D Tensor @output_9:out0 type: float32
I Build LeNet complete.
D Thinning network with DeadChannelRemoval, to zeros: True.
D Build analyzer ...
D Forward analyze range.
D Backward analyze range.
D Forward analyze range.
D Backward analyze range.
D Analyze range done.
D *********** Setup input meta ***********
D *********** Setup database (1) ***********
D Setup provider layer "text_input_layer":
D Lids: ['input_0']
D Layouts: ['nchw']
D Shapes: [[1, 1, 28, 28]]
D Data types: ['float32']
D Sparse tensors: []
D Tensor names(H5FS only): []
D Add preprocess "[('reverse_channel', True), ('mean', [0]), ('scale', 1.0), ('preproc_node_params', ordereddict([('add_preproc_node', False), ('preproc_type', 'IMAGE_RGB'), ('preproc_perm', [0, 1, 2, 3])]))]" for "input_0"
D *********** Setup input meta complete ***********
D Process input_0 ...
D Acuity output shape(input): (1 1 28 28)
D Tensor @input_0:out0 type: float32
D Real output shape: (1, 1, 28, 28)
D Process conv1_1_acuity_mark_perm_10 ...
D Acuity output shape(permute): (1 28 28 1)
D Tensor @conv1_1_acuity_mark_perm_10:out0 type: asymmetric_affine
D Real output shape: (1, 28, 28, 1)
D Process conv1_1 ...
D Acuity output shape(convolution): (1 24 24 20)
D Tensor @conv1_1:out0 type: asymmetric_affine
D Real output shape: (1, 24, 24, 20)
D Process pool1_2 ...
D Acuity output shape(pooling): (1 12 12 20)
D Tensor @pool1_2:out0 type: asymmetric_affine
D Real output shape: (1, 12, 12, 20)
D Process conv2_3 ...
D Acuity output shape(convolution): (1 8 8 50)
D Tensor @conv2_3:out0 type: asymmetric_affine
D Real output shape: (1, 8, 8, 50)
D Process pool2_4 ...
D Acuity output shape(pooling): (1 4 4 50)
D Tensor @pool2_4:out0 type: asymmetric_affine
D Real output shape: (1, 4, 4, 50)
D Process ip1_5 ...
D Acuity output shape(fullconnect): (1 500)
D Tensor @ip1_5:out0 type: asymmetric_affine
D Real output shape: (1, 500)
D Process relu1_6 ...
D Acuity output shape(relu): (1 500)
D Tensor @relu1_6:out0 type: asymmetric_affine
D Real output shape: (1, 500)
D Process ip2_7 ...
D Acuity output shape(fullconnect): (1 10)
D Tensor @ip2_7:out0 type: asymmetric_affine
D Real output shape: (1, 10)
D Process prob_8 ...
D Acuity output shape(softmax): (1 10)
D Tensor @prob_8:out0 type: float32
D Real output shape: (1, 10)
D Process output_9 ...
D Acuity output shape(output): (1 10)
D Tensor @output_9:out0 type: float32
D Real output shape: (1, 10)
I Build LeNet complete.
I Running 1 iterations
D 0(100.00%), Queue size 0
I Queue cancelled.
D Quantize tensor @conv1_1:out0.
D Quantize tensor @pool1_2:out0.
D Quantize tensor @conv2_3:out0.
D Quantize tensor @pool2_4:out0.
D Quantize tensor @ip1_5:out0.
D Quantize tensor @relu1_6:out0.
D Quantize tensor @ip2_7:out0.
D Quantize tensor @conv1_1_acuity_mark_perm_10:out0.
D Quantize tensor @conv1_1:weight.
D Quantize tensor @conv2_3:weight.
D Quantize tensor @ip1_5:weight.
D Quantize tensor @ip2_7:weight.
D Quantize tensor @conv1_1:bias.
D Quantize tensor @conv2_3:bias.
D Quantize tensor @ip1_5:bias.
D Quantize tensor @ip2_7:bias.
I Clean.
D Optimizing network with align_quantize, broadcast_quantize, qnt_adjust_coef, qnt_adjust_param
D Quantize tensor(@input_0:out0) with tensor(@conv1_1_acuity_mark_perm_10:out0)
D Quantize tensor(@pool1_2:out0) with tensor(@conv1_1:out0)
D Quantize tensor(@pool2_4:out0) with tensor(@conv2_3:out0)
I End quantization...
I Dump net quantize tensor table to lenet_uint8.quantize
I Save net to lenet.data
I ----------------Error(0),Warning(0)----------------
SUCCESS 
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0

user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ ls
bin             COPYRIGHTS  lenet   LICENSE          pegasus_export_ovx.sh  pegasus_inference.sh  README.md          requirements.txt
build_linux.sh  env.sh      lenet1  pegasus_dump.sh  pegasus_import.sh      pegasus_quantize.sh   release_notes.txt

user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ ./pegasus_inference.sh lenet/ uint8
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0
=======================================================================
= Start Inference lenet model with type of uint8 =======
=======================================================================
using  lenet_uint8.quantize 
python3 /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/bin/pegasus.py inference --model lenet.json --model-data lenet.data --dtype quantized --model-quantize lenet_uint8.quantize --iterations 1 --device CPU --output-dir ./inf/${NAME}_uint8 --with-input-meta lenet_inputmeta.yml
2021-09-28 18:28:11.840222: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory
2021-09-28 18:28:11.840252: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
I Namespace(batch_size=0, device='CPU', dtype='quantized', iterations=1, model='lenet.json', model_data='lenet.data', model_quantize='lenet_uint8.quantize', output_dir='./inf/lenet_uint8', postprocess='classification_classic', postprocess_file=None, which='inference', with_input_meta='lenet_inputmeta.yml')
I Load model in lenet.json
I Load data in lenet.data
I Load input meta lenet_inputmeta.yml
I Load quantization tensor table lenet_uint8.quantize
I Start inference...
2021-09-28 18:28:13.974372: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2021-09-28 18:28:13.980142: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2599990000 Hz
2021-09-28 18:28:13.980351: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x6a2a0b0 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2021-09-28 18:28:13.980369: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2021-09-28 18:28:13.982102: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory
2021-09-28 18:28:13.982129: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)
2021-09-28 18:28:13.982148: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (300S): /proc/driver/nvidia/version does not exist
D *********** Setup input meta ***********
D *********** Setup database (1) ***********
D Setup provider layer "text_input_layer":
D Lids: ['input_0']
D Layouts: ['nchw']
D Shapes: [[1, 1, 28, 28]]
D Data types: ['float32']
D Sparse tensors: []
D Tensor names(H5FS only): []
D Add preprocess "[('reverse_channel', True), ('mean', [0]), ('scale', 1.0), ('preproc_node_params', ordereddict([('add_preproc_node', False), ('preproc_type', 'IMAGE_RGB'), ('preproc_perm', [0, 1, 2, 3])]))]" for "input_0"
D *********** Setup input meta complete ***********
D Process input_0 ...
D Acuity output shape(input): (1 1 28 28)
D Tensor @input_0:out0 type: asymmetric_affine
D Real output shape: (1, 1, 28, 28)
D Process conv1_1_acuity_mark_perm_10 ...
D Acuity output shape(permute): (1 28 28 1)
D Tensor @conv1_1_acuity_mark_perm_10:out0 type: asymmetric_affine
D Real output shape: (1, 28, 28, 1)
D Process conv1_1 ...
D Acuity output shape(convolution): (1 24 24 20)
D Tensor @conv1_1:out0 type: asymmetric_affine
D Real output shape: (1, 24, 24, 20)
D Process pool1_2 ...
D Acuity output shape(pooling): (1 12 12 20)
D Tensor @pool1_2:out0 type: asymmetric_affine
D Real output shape: (1, 12, 12, 20)
D Process conv2_3 ...
D Acuity output shape(convolution): (1 8 8 50)
D Tensor @conv2_3:out0 type: asymmetric_affine
D Real output shape: (1, 8, 8, 50)
D Process pool2_4 ...
D Acuity output shape(pooling): (1 4 4 50)
D Tensor @pool2_4:out0 type: asymmetric_affine
D Real output shape: (1, 4, 4, 50)
D Process ip1_5 ...
D Acuity output shape(fullconnect): (1 500)
D Tensor @ip1_5:out0 type: asymmetric_affine
D Real output shape: (1, 500)
D Process relu1_6 ...
D Acuity output shape(relu): (1 500)
D Tensor @relu1_6:out0 type: asymmetric_affine
D Real output shape: (1, 500)
D Process ip2_7 ...
D Acuity output shape(fullconnect): (1 10)
D Tensor @ip2_7:out0 type: asymmetric_affine
D Real output shape: (1, 10)
D Process prob_8 ...
D Acuity output shape(softmax): (1 10)
D Tensor @prob_8:out0 type: float32
D Real output shape: (1, 10)
D Process output_9 ...
D Acuity output shape(output): (1 10)
D Tensor @output_9:out0 type: float32
D Real output shape: (1, 10)
I Build LeNet complete.
I Running 1 iterations
I Save tensor ./inf/lenet_uint8/iter_0_output_9_out0_1_10.tensor
I Save tensor ./inf/lenet_uint8/iter_0_input_0_out0_1_1_28_28.tensor
I Iter(0), top(5), tensor(@output_9:out0) :
I 0: 1.0
I 9: 0.0
I 8: 0.0
I 7: 0.0
I 6: 0.0
I Check const pool...
I End inference...
I ----------------Error(0),Warning(0)----------------
I Queue cancelled.
=========== End  inference lenet model  ===========
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0

user@300S:/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0$ ./pegasus_export_ovx.sh lenet/ uint8
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0
=======================================================================
=========== Start Generate lenet ovx C code with type of uint8 ===========
=======================================================================
using  lenet_uint8.quantize 
python3 /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/bin/pegasus.py export ovxlib --model lenet.json --model-data lenet.data --dtype quantized --model-quantize lenet_uint8.quantize --target-ide-project 'linux64' --with-input-meta lenet_inputmeta.yml --output-path ./wksp/${NAME}_${QUANTIZED}/lenet_uint8
2021-09-28 18:28:41.176535: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory
2021-09-28 18:28:41.176566: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
I Namespace(batch_size=None, build_platform='make', customer_lids=None, customer_ops=None, dtype='quantized', export='ovxlib', force_remove_permute=False, model='lenet.json', model_data='lenet.data', model_quantize='lenet_uint8.quantize', optimize='Default', output_path='./wksp/lenet_uint8/lenet_uint8', pack_nbg_unify=False, pack_nbg_viplite=False, pack_vdata=False, postprocess_file=None, save_fused_graph=False, target_ide_project='linux64', viv_sdk=None, which='export', with_input_meta='lenet_inputmeta.yml')
I Load model in lenet.json
I Load data in lenet.data
I Load input meta lenet_inputmeta.yml
I Load quantization tensor table lenet_uint8.quantize
I Start exporting ovxlib case...
2021-09-28 18:28:43.296904: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2021-09-28 18:28:43.302706: I tensorflow/core/platform/profile_utils/cpu_utils.cc:104] CPU Frequency: 2599990000 Hz
2021-09-28 18:28:43.302940: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x6a496e0 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2021-09-28 18:28:43.302960: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2021-09-28 18:28:43.305041: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory
2021-09-28 18:28:43.305064: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)
2021-09-28 18:28:43.305085: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (300S): /proc/driver/nvidia/version does not exist
D Process input_0 ...
D Acuity output shape(input): (1 1 28 28)
D Tensor @input_0:out0 type: asymmetric_affine
D Process conv1_1_acuity_mark_perm_10 ...
D Acuity output shape(permute): (1 28 28 1)
D Tensor @conv1_1_acuity_mark_perm_10:out0 type: asymmetric_affine
D Process conv1_1 ...
D Acuity output shape(convolution): (1 24 24 20)
D Tensor @conv1_1:out0 type: asymmetric_affine
D Process pool1_2 ...
D Acuity output shape(pooling): (1 12 12 20)
D Tensor @pool1_2:out0 type: asymmetric_affine
D Process conv2_3 ...
D Acuity output shape(convolution): (1 8 8 50)
D Tensor @conv2_3:out0 type: asymmetric_affine
D Process pool2_4 ...
D Acuity output shape(pooling): (1 4 4 50)
D Tensor @pool2_4:out0 type: asymmetric_affine
D Process ip1_5 ...
D Acuity output shape(fullconnect): (1 500)
D Tensor @ip1_5:out0 type: asymmetric_affine
D Process relu1_6 ...
D Acuity output shape(relu): (1 500)
D Tensor @relu1_6:out0 type: asymmetric_affine
D Process ip2_7 ...
D Acuity output shape(fullconnect): (1 10)
D Tensor @ip2_7:out0 type: asymmetric_affine
D Process prob_8 ...
D Acuity output shape(softmax): (1 10)
D Tensor @prob_8:out0 type: float32
D Process output_9 ...
D Acuity output shape(output): (1 10)
D Tensor @output_9:out0 type: float32
I Build LeNet complete.
I Initialzing network optimizer by Default ...
D Optimizing network with merge_ximum, qnt_adjust_coef, multiply_transform, add_extra_io, format_input_ops, auto_fill_zero_bias, conv_kernel_transform, strip_op, extend_unstack_split, merge_layer, transform_layer, broadcast_op, strip_op, auto_fill_reshape_zero, adjust_output_attrs, insert_dtype_converter
I Start T2C Switcher...
D Optimizing network with broadcast_op, t2c_fc
D insert permute conv1_1_acuity_mark_perm_11 before conv1_1
D remove permute conv1_1_acuity_mark_perm_10
D remove permute conv1_1_acuity_mark_perm_11
I End T2C Switcher...
D Process input_0 ...
D Acuity output shape(input): (1 1 28 28)
D Tensor @input_0:out0 type: asymmetric_affine
D Process conv1_1 ...
D Acuity output shape(convolution): (1 20 24 24)
D Tensor @conv1_1:out0 type: asymmetric_affine
D Process pool1_2 ...
D Acuity output shape(pooling): (1 20 12 12)
D Tensor @pool1_2:out0 type: asymmetric_affine
D Process conv2_3 ...
D Acuity output shape(convolution): (1 50 8 8)
D Tensor @conv2_3:out0 type: asymmetric_affine
D Process pool2_4 ...
D Acuity output shape(pooling): (1 50 4 4)
D Tensor @pool2_4:out0 type: asymmetric_affine
D Process ip1_5 ...
D Acuity output shape(fullconnect): (1 500)
D Tensor @ip1_5:out0 type: asymmetric_affine
D Process relu1_6 ...
D Acuity output shape(relu): (1 500)
D Tensor @relu1_6:out0 type: asymmetric_affine
D Process ip2_7 ...
D Acuity output shape(fullconnect): (1 10)
D Tensor @ip2_7:out0 type: asymmetric_affine
D Process prob_8 ...
D Acuity output shape(softmax): (1 10)
D Tensor @prob_8:out0 type: float32
D Process output_9 ...
D Acuity output shape(output): (1 10)
D Tensor @output_9:out0 type: float32
I Build LeNet complete.
D Optimizing network with conv_1xn_transform, proposal_opt, c2drv_convert_axis, c2drv_convert_shape, c2drv_convert_array, c2drv_cast_dtype, c2drv_trans_data
I Building data ...
I Packing data ...
D Packing conv1_1 ...
D Quantize @conv1_1:bias to asymmetric_affine.
D Quantize @conv1_1:weight to asymmetric_affine.
D Packing conv2_3 ...
D Quantize @conv2_3:bias to asymmetric_affine.
D Quantize @conv2_3:weight to asymmetric_affine.
D Packing ip1_5 ...
D Quantize @ip1_5:bias to asymmetric_affine.
D Quantize @ip1_5:weight to asymmetric_affine.
D Packing ip2_7 ...
D Quantize @ip2_7:bias to asymmetric_affine.
D Quantize @ip2_7:weight to asymmetric_affine.
I Saving data to ./wksp/lenet_uint8/lenet_uint8.export.data
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_lenetuint8.c
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_lenetuint8.h
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_post_process.c
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_post_process.h
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_pre_process.c
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_pre_process.h
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/vnn_global.h
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/main.c
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/Android.mk
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/BUILD
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/lenetuint8.vcxproj
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/makefile.linux
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/.cproject
I Save vx network source file to /media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0/lenet/wksp/lenet_uint8/.project
I End exporting ovxlib case...
I ----------------Error(0),Warning(0)----------------
=======================================================================
=========== End  Generate lenet ovx C code with type of  ===========
=======================================================================
/media/user/Program/IC_VeriSilicon/tools/acuity-toolkit-whl-5.24.0
